package com.jelly.designpattern.decorator;

public class HotSaleTag extends TagDecorator {
	TagComponent tagComponent;

	public HotSaleTag(TagComponent tagComponent) {
		tagName = "hot-sale-tag";
		this.tagComponent = tagComponent;
	}

	@Override
	public void addTag() {
		tagComponent.addTag();
		// 需要添加的操作（装饰）
		addHotSaleTag();
	}

	private void addHotSaleTag() {
		System.out.println("add " + tagName);
	}
}
